<!DOCTYPE html>
<html>
   <head>
      <meta charset="utf-8" />
      <title>New image example - jQuery in Action, 3rd edition</title>
      <link rel="stylesheet" href="../css/main.css"/>
      <style>
         img
         {
            display: block;
            margin: auto;
         }
      </style>
   </head>
   <body>
      <script src="../js/jquery-1.11.3.min.js"></script>
      <script>
         $('<img>',
         {
            src: '../images/little.bear.png',
            alt: 'Little Bear',
            title:'I woof in your general direction',
            click: function() {
               alert($(this).attr('title'));
            }
         })
         .appendTo('body');
      </script>
   </body>
</html>
